package com.brillilab.dao.mapper.comments;

import java.util.List;

import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.brillilab.domain.po.comments.ChatMessage;
import com.brillilab.domain.vo.comments.ChatClassifySearchVo;
import com.brillilab.domain.vo.comments.ChatContentSearchVo;
import com.brillilab.domain.vo.comments.ChatMessageFileVo;
import com.brillilab.domain.vo.comments.ChatFileSearchVo;
import com.brillilab.domain.vo.comments.ChatSearchClassifyVo;

/**
 * 聊天消息
 * 
 * @author
 * @date 2019/12/03
 */
@Mapper
public interface ChatMessageMapper extends BaseMapper<ChatMessage> {

	ChatMessage getNewestOneMessage(@Param("meMemberId") Long meMemberId, @Param("otherMemberId") Long otherMemberId);

	List<ChatMessage> historyMessage(@Param("meMemberId") Long meMemberId, @Param("otherMemberId") Long otherMemberId,
			@Param("startMessageId") Long startMessageId);

	List<ChatMessage> newestMessage(@Param("meMemberId") Long meMemberId, @Param("otherMemberId") Long otherMemberId,
			@Param("startMessageId") Long startMessageId);

	List<ChatMessage> searchContent(@Param("searchVo") ChatContentSearchVo searchVo);

	List<ChatMessageFileVo> searchPicture(@Param("searchVo") ChatFileSearchVo searchVo);

	List<ChatSearchClassifyVo> searchClassify(@Param("searchVo") ChatClassifySearchVo searchVo);

}
